package cn.cycleif.entity;

import cn.cycleif.enums.CommonStatusEnum;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.time.LocalDateTime;

/**
 * @Date: 25/2/8-21:17
 * @Desc:
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
public class Answer {

  @TableId(type = IdType.AUTO)
  private Integer          id;
  private Integer          questionId;
  private Integer          userId;
  private CommonStatusEnum status;
  private Integer          voteCount;
  private Integer          commentCount;
  private String           content;
  private Integer          lastEditUserId;
  private Integer          revisionId;
  private Integer          adopted;

  @TableField(fill = FieldFill.INSERT)
  private LocalDateTime createAt;
  @TableField(fill = FieldFill.UPDATE)
  private LocalDateTime updateAt;
}
